/**
 * Copyright &copy; 2012-2016 <a href="https://github.com/thinkgem/jeesite">JeeSite</a> All rights reserved.
 */
package com.longview.io.modules.livestockinfo.service;

import java.util.List;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.longview.io.common.persistence.Page;
import com.longview.io.common.service.CrudService;
import com.longview.io.modules.livestockinfo.entity.UserLivestockInfo;
import com.longview.io.modules.livestockinfo.dao.UserLivestockInfoDao;

/**
 * 用户牲畜信息Service
 * @author zf
 * @version 2018-04-23
 */
@Service
@Transactional(readOnly = true)
public class UserLivestockInfoService extends CrudService<UserLivestockInfoDao, UserLivestockInfo> {

	public UserLivestockInfo get(String id) {
		return super.get(id);
	}
	
	public List<UserLivestockInfo> findList(UserLivestockInfo userLivestockInfo) {
		return super.findList(userLivestockInfo);
	}
	
	public Page<UserLivestockInfo> findPage(Page<UserLivestockInfo> page, UserLivestockInfo userLivestockInfo) {
		return super.findPage(page, userLivestockInfo);
	}
	
	@Transactional(readOnly = false)
	public void save(UserLivestockInfo userLivestockInfo) {
		super.save(userLivestockInfo);
	}
	
	@Transactional(readOnly = false)
	public void delete(UserLivestockInfo userLivestockInfo) {
		super.delete(userLivestockInfo);
	}
	public List<UserLivestockInfo> findSumList(UserLivestockInfo userLivestockInfo)
	{
		return dao.findSumList(userLivestockInfo);
	}
	public List<UserLivestockInfo> findptList(UserLivestockInfo userLivestockInfo)
	{
		return dao.findptList(userLivestockInfo);
	}
	
	public Page<UserLivestockInfo> findPagepdtList(Page<UserLivestockInfo> page, UserLivestockInfo userLivestockInfo)
	{
		userLivestockInfo.setPage(page);
		page.setList(dao.findptList(userLivestockInfo));
		return page; 
	}
}